Introduction (Tamer)

The Opioid Crisis is truly that - a crisis. Over the past 20 years, opioids have become a commonly used recreational drug. As people use these drugs, they become addicted. Opioid abuse often starts with a legitimate prescription as a treatment for pain. However, the addictive nature of the drug can cause people to seek out more opioids after their prescription is over. In small doses, opioids are effective painkillers that may make you feel drowsy. In large doses (abuse), opioids can result in slowed breathing and a slowed heart-rate. These effects can cause death - otherwise known as an overdose.

The amount of opioids prescribed began growing a lot and peaked in 2012 with 255 million doses prescribed. Since 2012, overall doses prescribed has diminished to 168 million in 2018; however, that is still a huge number of opioid doses. Unfortunately, overdoses have also been on the rise and - unlike prescriptions - are continuing to rise (as can be seen in the figure below).

image The mechanism by which legitimate prescriptions may lead someone down the path to opioid abuse and potentially overdosing is one of addiction. When someone is legally prescribed opioids (potentially an excessive number of doses) they are subject to developing an addiction. If they do, then they may go searching for more opioids after their prescription runs out. The most common replacements are drugs like heroin and fentanyl. Heroin and fentanyl, which is over 100 times the strength of morphine - a notoriously powerful painkiller, are very strong opioids that can very easily lead to overdose even after just one use. It is also worth noting that even prescription opioids cause deaths, not just the super strong types.

For this project, we wanted to explore the relationship between opioid prescription rate and overdose rate, figure out which (if there are any) states are disproportionately affected, and

Data

Prescription Rate Data (Tamer)

Overdose Rate Data (Chris)

Analysis

Prescription Rate vs. Overdose Rate (Chris)

  1. Show maps
  2. Ask Questions about whether one causes the other, etc.

Regression

# scatter / regression between prescription rate and overdose rate
mod <- lm(age_adjusted_rate ~ prescription_rate, data = full_data)
msummary(mod)
##                   Estimate Std. Error t value Pr(>|t|)   
## (Intercept)        7.56323    2.96818   2.548  0.01409 * 
## prescription_rate  0.10475    0.03524   2.972  0.00461 **
## 
## Residual standard error: 5.298 on 48 degrees of freedom
## Multiple R-squared:  0.1554, Adjusted R-squared:  0.1379 
## F-statistic: 8.835 on 1 and 48 DF,  p-value: 0.004609
ggplot(data = full_data, aes(x = prescription_rate)) +
  geom_histogram(bins = 15)

ggplot(data = full_data, aes(x = prescription_rate, y = age_adjusted_rate)) +
  geom_point() + 
  geom_abline(intercept = 7.56323, slope = 0.10475)

Clustering (Sean)

Text explaining why k-means

Determining the Optimal K

Explain silhouette score

silhouette_score <- function(k){
  km <- kmeans(full_data[, 2:3], centers = k, nstart = 20)
  score <- cluster::silhouette(km$cluster, dist(full_data[, 2:3]))
  mean(score[, 3])
}

k <- 2:5
avg_sil <- sapply(k, silhouette_score)
optimal_k <- which(as.data.frame(avg_sil)$avg_sil == max(avg_sil)) + 1
optimal_k
## [1] 2
km <- kmeans(full_data[, 2:3], centers = optimal_k, nstart = 20)
full_data <- mutate(full_data, cluster = as.character(km$cluster))

Clustering for 2014

text about the clustering

Conclusion (Chris, Sean)